<%@ page language="java" import="java.util.*" pageEncoding="utf-8"%>
<header id="header">
	
            <div  style="background-color: #333;height: 44px;box-shadow: 0 1px 2px rgba(0,0,0,0.5);position: absolute;top: 0;width: 100%;display: block;">
            <div style="position: relative;width: 1000px;padding: 0 7px;margin: 0 auto;">
                <div  style="position: relative;float: left;height: 44px;width: 520px;">
                 <img src="images/logo.jpg"  style="position:absolute; margin-left:-80px; margin-top:9px;" width="71px" height="27px;">
                    <ul>
                    	<%
						    String isroot=(String)session.getAttribute("IsRoot");
						    if("yes".equals(isroot)){
						 %>
						<li style="font-size: 16px;float: left; display: block; padding: 10px 12px; "><a href="index.jsp">首页</a></li>
                      	<li style="font-size: 16px;float: left; display: block; padding: 10px 12px; "><a href="message_root.jsp?findmessage=<%=""%>">留言薄</a></li>
						<li style="font-size: 16px;float: left; display: block; padding: 10px 12px; "><a href="classmates.jsp?finduser=<%=""%>">同学录</a></li>
						<li style="font-size: 16px;float: left; display: block; padding: 10px 12px;background-color:#3366CC; "><a href="usermanage.jsp" style="color:#FFFFFF;">用户管理</a></li>
						 <%
						    } else {
						  %>
                        <li style="font-size: 16px;float: left; display: block; padding: 10px 12px; "><a href="index.jsp">首页</a></li>
                      	<li style="font-size: 16px;float: left; display: block; padding: 10px 12px; "><a href="message_control.do">留言薄</a></li>
                      	<li style="font-size: 16px;float: left; display: block; padding: 10px 12px; "><a href="takemessage.jsp?tousername=<%=""%>">写留言</a></li>
						<li style="font-size: 16px;float: left; display: block; padding: 10px 12px; "><a href="classmates.jsp?finduser=<%=""%>">通讯录</a></li>
			            <%} %>
                    </ul>
                </div>
				
<style>
.nav-right {
position: relative;
float: right;
height: 44px;
padding-top: 6px;
}
.nav-right .nav-search {
color: #ccc;
z-index: 1;
}
.nav-right .nav-search, .nav-right .nav-publish-wrapper, .nav-right .nav-personal {
float: left;
margin-left: .8em;
height: 30px;
position: relative;
}
.nav-right .nav-search .batch-search {
position: absolute;
left: 4px;
top: 7px;
}
.icon-batch-small, .icon-batch-base, .icon-batch-large, .prefix-batch:before {
font-family: "Batch";
-webkit-font-smoothing: antialiased;
text-decoration: none;
}
.icon-batch-small, .icon-small, .icon-sns-small {
display: inline-block;
font-size: 16px;
height: 16px;
width: 16px;
}
.icon-st {
opacity: .5;
}


.nav-right .nav-search input {
width: 150px;
font-size: 14px;
line-height: 14px;
height: 30px;
color: #ccc;
vertical-align: middle;
border: none;
border-radius: 2px;
box-shadow: none;
padding-left: 24px;
background-color: #2b2b2b;
}
.nav-right .nav-search ul{display:none;background-color:#2b2b2b; }.nav-right .nav-search ul li a{padding:6px 4px;display:block}.nav-right .nav-search ul li.active{background-color:#333}.nav-right .nav-search.active ul{display:block}.nav-right .nav-dropdown-menu{position:absolute;top:100%;left:0;z-index:1000;display:none;width:100%;font-size:14px;list-style:none;background-color:#2b2b2b;box-shadow:0 2px 3px rgba(0,0,0,0.18);background-clip:padding-box;border:none;border-bottom-right-radius:2px;border-bottom-left-radius:2px}.nav-right .nav-dropdown-menu li a{text-decoration:none;display:block}.nav-right .nav-dropdown-menu li a:hover{background-color:#333}.nav-right .nav-publish-wrapper{width:72px}.nav-right .nav-publish-wrapper .btn-publish{background-color:#259;color:white;display:block;font-weight:bold;text-align:center;text-indent:.5em;padding:0;line-height:30px;height:30px;border-radius:2px}.nav-right .nav-publish-wrapper .nav-dropdown-menu li a{padding:0 12px;line-height:36px}.nav-right .nav-publish-wrapper:hover .nav-dropdown-menu{display:block}.nav-right .nav-personal{background-color:#2b2b2b;width:130px;border-radius:2px}.nav-right .nav-personal .nav-personal-info{display:block;text-decoration:none;line-height:30px;padding:0 0 0 34px;color:#ccc;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.nav-right .nav-personal img.nav-personal-avatar{position:absolute;top:0;left:0;width:30px;height:30px;border-top-left-radius:2px;border-top-right-radius:0;border-bottom-right-radius:0;border-bottom-left-radius:2px}.nav-right .nav-personal .personal-menu{width:160px}.nav-right .nav-personal .personal-menu li a{padding:0 1em;line-height:36px}.nav-right .nav-personal:hover .nav-dropdown-menu,.nav-right .nav-personal.hover .nav-dropdown-menu{display:block}.nav-right .nav-messages{float:left;width:30px;height:30px;background-color:#555;display:inline;border-top-right-radius:2px;border-top-left-radius:0;border-bottom-left-radius:0;border-bottom-right-radius:2px}.nav-right .nav-messages .icon-batch-small{margin:7px}.btn-header{padding:0 .5em;margin-left:.8em;height:30px;line-height:30px;border:none;background-color:#555;display:inline-block;border-radius:2px}.btn-header-border{background:none;color:#777;border:1px solid #555}.navbar-secondary{height:60px;padding-top:16px;background-color:#f8f8f8}.navbar-secondary .container{width:1000px}.navbar-secondary.navbar-fixed-top{height:44px;padding-top:0;box-shadow:0 1px 2px rgba(0,0,0,0.2)}.navbar-secondary .navbar-title>a,.navbar-secondary .navbar-subnav li a{color:#555;text-decoration:none;display:block;line-height:44px}.navbar-secondary .navbar-title{font-size:14px;float:left;padding:0}.navbar-secondary .navbar-title>a{background-color:#eee;color:#555;box-shadow:0 1px 1px #cecece inset;text-align:center;text-indent:.5em;line-height:30px;height:30px;border-radius:2px;font-weight:bold;padding:0 10px;margin:7px 0}
</style>				

                <div class="nav-right">
                    <div class="nav-search">
                        
                        <form action="" method="get">
							<img src="images/sousuo.png" style="position:absolute; margin-top:6px;">
                           <input  placeholder="搜索"  onClick="alert('开发中...')">
                        </form>
                    </div>
					
					 <%
                             String StrYes = (String )session.getAttribute("yes");
                             String username = (String) session.getAttribute("username");
                             if(!("yes".equals(StrYes))){
                     %>
				 

                        <a id="registerAnchor" class="btn btn-header" href="signup.jsp" style="position:absolute;" >注册</a>
                        <a class="btn btn-header btn-header-border" href="login.jsp?from=0" style="position:absolute; margin-left:65px;" >登录</a>
					<%
						}else{
					%>
						
						<div class="nav-personal" >
                            <a class="nav-personal-info" href="index.jsp">
                                <img class="nav-personal-avatar" src="images/noavatar_small.gif" alt="<% out.print(username); %> " />
                                <% out.print(username); %>
                             </a>
                            <menu class="nav-dropdown-menu personal-menu">
                            	<%
						            if(!"yes".equals(isroot)){
						        %>
                                <li><a href="person.jsp" title="我的相册" class="prefix-batch batch-grid">我的信息</a></li>
                                <li><a href="person_message.jsp?findmessage=" title="我的留言" class="prefix-batch batch-grid">我的留言</a></li>
                                <%} %>
                                <li style="border-top:1px solid #555;"><a  href="exit">注销</a></li>
                            </menu>
                        </div>
						
						<%} %>
					
                 </div>
            </div>
        </div>
    </header>